﻿CREATE TABLE [dbo].[mark_Bookmark] (
    [BookmarkId]  BIGINT           IDENTITY (1, 1) NOT NULL,
    [TextId]      BIGINT           NOT NULL,
    [UserId]      UNIQUEIDENTIFIER NOT NULL,
    [Title]       NVARCHAR (256)   NOT NULL,
    [IsUserTitle] BIT              CONSTRAINT [DF_mark_Bookmark_IsUserTitle] DEFAULT ((0)) NOT NULL,
    CONSTRAINT [PK_mark_Bookmark] PRIMARY KEY CLUSTERED ([BookmarkId] ASC),
    CONSTRAINT [FK_mark_Bookmark_mark_Bookmark] FOREIGN KEY ([TextId]) REFERENCES [dbo].[text_Text] ([TextId]),
    CONSTRAINT [FK_mark_Bookmark_user_User] FOREIGN KEY ([UserId]) REFERENCES [dbo].[user_User] ([UserId])
);

